Structural Recursion as a Query Language yVal
نویسنده
چکیده
We propose a programming paradigm that tries to get close to both the semantic simplicity of rela-tional algebra, and the expressive power of unrestricted programming languages. Its main computational engine is structural recursion on sets. All programming is done within a \nicely" typed lambda calculus, as in Machiavelli OBB89]. A guiding principle is that how queries are implemented is as important as whether they can be implemented. As in relational algebra, the meaning of any relation transformer is guaranteed to be a total map taking nite relations to nite relations. A naturally restricted class of programs written with structural recursion has precisely the expressive power of the relational algebra. The same programming paradigm scales up, yielding query languages for the complex-object model AB89]. Beyond that, there are, for example, eecient programs for transitive closure and we are also able to write programs that move out of sets, and then perhaps back to sets, as long as we stay within a (quite exible) type system. The uniform paradigm of the language suggests positive expectations for the optimization problem. In fact, structural recursion yields ner grain programming therefore we expect that lower-level, and therefore better optimizations will be feasible.
منابع مشابه
UnQL : A Query Language and Algebra for Semistructured DataBased on Structural
This paper presents structural recursion as the basis of the syntax and semantics of query languages for semistructured data and XML. We describe a simple and powerful query language based on pattern matching and show that it can be expressed using structural recursion, which is introduced as a top-down, recursive function, similar to the way XSL is deened on XML trees. On cyclic data, structur...
متن کاملStructural Recursion as a Query Language
We propose a programming paradigm that tries to get close to both the semantic simplicity of relational algebra, and the expressive power of unrestricted programming languages. Its main computational engine is structural recursion on sets. All programming is done within a "nicely" typed lambda calculus, as in Machiavelli [OBB89]. A guiding principle is that how queries are implemented is as imp...
متن کاملSome Properties of Query Languages for Bags
In this paper we study the expressive power of query languages for nested bags. We deene the ambient bag language by generalizing the constructs of the relational language of Breazu-Tannen, Buneman and Wong, which is known to have precisely the power of the nested relational algebra. Relative strength of additional polynomial constructs is studied, and the ambient language endowed with the stro...
متن کاملA Conserative Property of a Nested Relational Query Language
We proposed in [7] a nested relational calculus and a nested relational algebra based on structural recursion [6,5] and on monads [27,16]. In this report, we describe relative set abstraction as our third nested relational query language. This query language is similar to the well known list comprehension mechanism in functional programming languages such as Haskell [ll], Miranda [24], KRC [23]...
متن کاملQuery Languages for Bags and Aggregate Functions
Theoretical foundations for querying databases based on bags are studied in this paper. We fully determine the strength of many polynomial-time bag operators relative to an ambient query language. Then we obtain BQL, a query language for bags, by picking the strongest combination of these operators. The relationship between the nested relational algebra and various fragments of BQL is investiga...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 1991